import { object_Inf } from "@/utils/typings/index.type";

//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.aoi")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.aoiAllYieldRate")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.formingOutput")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.cutEdgeOutput")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.aoiTestNum")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.aoiDefectRate")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.stackingOutput")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.formingUtilization")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.cutEdgeUtilization")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.aoiUtilization")
//t("page.dashboardManageArr.produceDashboard.outputDataTypeArr.formingUseRate")
//--------
//t("page.dashboardManageArr.produceDashboard.outputCountArr.aoi")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.aoiAllYieldRate")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.formingOutput")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.cutEdgeOutput")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.aoiTestNum")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.aoiDefectRate")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.stackingOutput")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.formingUtilization")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.cutEdgeUtilization")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.aoiUtilization")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.formingUseRate")
/*
 * @Descripttion:产出数类型枚举
 * @LastEditors: xzh
 * @LastEditTime: 2023-11-19 21:46:56
 */
export enum produceDataTypeEnum {
  aoi = "aoi", //	AOI制程良率
  aoiAllYieldRate = "aoiAllYieldRate", //	AOI/CCD制程总平均良率推移图
  formingUtilization = "formingUtilization", //成型设备稼动率
  formingUseRate = "formingUseRate", //成型机整体利用率
  cutEdgeUtilization = "cutEdgeUtilization", //切箍边设备稼动率
  aoiUtilization = "aoiUtilization", //AOI设备稼动率
  formingOutput = "formingOutput", //成型制程产出数
  cutEdgeOutput = "cutEdgeOutput", //切箍边制程产出数
  aoiTestNum = "aoiTestNum", //各AOI/CCD检验数
  aoiDefectRate = "aoiDefectRate", //各AOI/CCD不良率
  stackingOutput = "stackingOutput", //堆叠制程产出数
}

/**
 * @Author: xzh
 * @Descripttion: 产出类型对应数据key枚举
 * @Param:
 */
export let produceDataKeyMap = {
  [produceDataTypeEnum.aoi]: "aoiYieldRateDto", //AOI 良率
  [produceDataTypeEnum.formingOutput]: "outputDto", //成型制程产出数
  [produceDataTypeEnum.cutEdgeOutput]: "trimOutputDto", //切箍边制程产出数
  [produceDataTypeEnum.aoiTestNum]: "aoiInspectionDto", //各AOI/CCD检验数
  [produceDataTypeEnum.aoiDefectRate]: "aoiBadRateDto", //各AOI/CCD不良率
  [produceDataTypeEnum.stackingOutput]: "stackingOutputDto", //堆叠制程产出数
  [produceDataTypeEnum.formingUtilization]: "utilizationRateDto", //成型设备稼动率
  [produceDataTypeEnum.cutEdgeUtilization]: "trimUtilizationRateDto", //切箍边设备稼动率
  [produceDataTypeEnum.aoiUtilization]: "aoiUtilizationRateDto", //AOI设备稼动率
  [produceDataTypeEnum.formingUseRate]: "usageRateDto", //成型机整体利用率
};

/**
 * @Author: xzh
 * @Descripttion: 设备数据类型枚举
 * @Param:
 */
export enum equipDataTypeEnum {
  FORMING = "FORMING", //成型机
  TRIM = "TRIM", //切箍边机
  AOI = "AOI", //AOI/CCD
  STACKING = "STACKING", //堆叠机
}

/**
 * @Author: xzh
 * @Descripttion: 生产数据类型映射
 * @Param:
 */
export let produceDataTypeMap = {
  [produceDataTypeEnum.aoi]: equipDataTypeEnum.AOI, //AOI 良率
  [produceDataTypeEnum.formingOutput]: equipDataTypeEnum.FORMING, //成型制程产出数
  [produceDataTypeEnum.cutEdgeOutput]: equipDataTypeEnum.TRIM, //切箍边制程产出数
  [produceDataTypeEnum.stackingOutput]: equipDataTypeEnum.STACKING, //堆叠制程产出数
  [produceDataTypeEnum.formingUtilization]: equipDataTypeEnum.FORMING, //成型设备稼动率
  [produceDataTypeEnum.cutEdgeUtilization]: equipDataTypeEnum.TRIM, //切箍边设备稼动率
  [produceDataTypeEnum.aoiUtilization]: equipDataTypeEnum.AOI, //AOI设备稼动率
  [produceDataTypeEnum.formingUseRate]: equipDataTypeEnum.FORMING, //成型机整体利用率
};
//t("page.dashboardManageArr.produceDashboard.outputCountArr.quality")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.cost")
//t("page.dashboardManageArr.produceDashboard.outputCountArr.delivery")
/**
 * @Author: xzh
 * @Descripttion: 生成分组
 * @Param:
 */
export let produceGroupMap = {
  quality: [produceDataTypeEnum.aoi, produceDataTypeEnum.aoiAllYieldRate],
  cost: [
    produceDataTypeEnum.formingUtilization,
    produceDataTypeEnum.formingUseRate,
    produceDataTypeEnum.cutEdgeUtilization,
    produceDataTypeEnum.aoiUtilization,
  ],
  delivery: [
    produceDataTypeEnum.formingOutput,
    produceDataTypeEnum.cutEdgeOutput,
    produceDataTypeEnum.aoiTestNum,
    produceDataTypeEnum.stackingOutput,
  ],
};
/**
 * @Author: xzh
 * @Descripttion: 生成图表颜色
 * @Param:
 */
export let produceChartColorMap = {
  // [produceDataTypeEnum.formingUtilization]: "#4472c4",
  // [produceDataTypeEnum.cutEdgeUtilization]: "#a5a5a5",
  // [produceDataTypeEnum.aoiUtilization]: "#548235",
};
/**
 * @Author: xzh
 * @Descripttion: 生成图标颜色
 * @Param:
 */
export let produceIconMap = {
  [produceDataTypeEnum.aoi]: "yieldRate",
  [produceDataTypeEnum.aoiAllYieldRate]: "yieldRate",
  [produceDataTypeEnum.formingUtilization]: "utilizeRate",
  [produceDataTypeEnum.cutEdgeUtilization]: "utilizeRate",
  [produceDataTypeEnum.formingUseRate]: "utilizeRate",
  [produceDataTypeEnum.aoiUtilization]: "utilizeRate",
  [produceDataTypeEnum.formingOutput]: "output",
  [produceDataTypeEnum.cutEdgeOutput]: "output",
  [produceDataTypeEnum.aoiTestNum]: "output",
  [produceDataTypeEnum.stackingOutput]: "output",
  [produceDataTypeEnum.aoiDefectRate]: "defectRate",
};
/**
 * @Author: xzh
 * @Descripttion: 图表y轴对应字段
 * @Param:
 */
export let chartFiel_Y = {
  [produceDataTypeEnum.aoi]: "aoiYieldRate",
  [produceDataTypeEnum.aoiTestNum]: "inspectionQuantity",
  [produceDataTypeEnum.formingOutput]: "outputQuantity",
  [produceDataTypeEnum.cutEdgeOutput]: "outputQuantity",
  [produceDataTypeEnum.stackingOutput]: "outputQuantity",
  [produceDataTypeEnum.aoiDefectRate]: "aoiBadRate",
  [produceDataTypeEnum.formingUtilization]: "utilizationRate",
  [produceDataTypeEnum.cutEdgeUtilization]: "utilizationRate",
  [produceDataTypeEnum.aoiUtilization]: "utilizationRate",
  [produceDataTypeEnum.formingUseRate]: "usageRate",
};

/**
 * @Author: xzh
 * @Descripttion: 产出过滤映射
 * @Param:
 */
export let produceFilterMap: object_Inf = {
  list: [],
  chart: [],
};
